﻿namespace Admin.NET.Core;

/// <summary>
/// 打印模板配置
/// </summary>
[SugarTable(null, "打印模板配置")]
[SysTable]
public partial class SysPrintTemplate : EntityTenant
{
    /// <summary>
    /// 名称
    /// </summary>
    [SugarColumn(ColumnName = "Name", ColumnDescription = "名称", Length = 160)]
    public string? Name { get; set; }

    /// <summary>
    /// Sql语句
    /// </summary>
    [SugarColumn(ColumnName = "SqlTemplate", ColumnDescription = "Sql语句", ColumnDataType = StaticConfig.CodeFirst_BigString)]
    public string? SqlTemplate { get; set; }

    /// <summary>
    /// 左侧字段
    /// </summary>
    [SugarColumn(ColumnName = "LeftFields", ColumnDescription = "左侧字段", ColumnDataType = StaticConfig.CodeFirst_BigString)]
    public string? LeftFields { get; set; }

    /// <summary>
    /// 打印模板
    /// </summary>
    [SugarColumn(ColumnName = "PrintTemplate", ColumnDescription = "打印模板", ColumnDataType = StaticConfig.CodeFirst_BigString)]
    public string? PrintTemplate { get; set; }

    /// <summary>
    /// 备注
    /// </summary>
    [SugarColumn(ColumnName = "Remark", ColumnDescription = "备注", Length = 500)]
    public string? Remark { get; set; }

    /// <summary>
    /// 数据状态
    /// </summary>
    [SugarColumn(ColumnName = "EnabledMark", ColumnDescription = "数据状态", Length = 32)]
    public int? EnabledMark { get; set; } = StatusEnum.Enable.ToInt();

    /// <summary>
    /// 连接数据Id
    /// </summary>
    [SugarColumn(ColumnName = "DbLinkId", ColumnDescription = "连接数据Id")]
    public long? DbLinkId { get; set; }

    /// <summary>
    /// 创建者部门Id
    /// </summary>
    [SugarColumn(ColumnName = "CreateOrgId", ColumnDescription = "创建者部门Id")]
    public long? CreateOrgId { get; set; }

    /// <summary>
    /// 创建者部门名称
    /// </summary>
    [SugarColumn(ColumnName = "CreateOrgName", ColumnDescription = "创建者部门名称", Length = 64)]
    public string? CreateOrgName { get; set; }
}